Quicken, Money and Mint alternative for Computer Scientists
Accounting for Computer Scientist by Martin Kleppmann uses graph theory from computer science to explain accounting.
In that spirit, I ask myself: how can computer science concepts help with these personal finance needs:
- Spending tracking and, therefore, budget tracking.
- Investment tracking.
There are existing tools that serve these needs:
Here are my requirements:
- Data is stored locally (i.e. not in the cloud) and in an open format.
- Business logic is open-source, portable and has plug-in API.
- GUI is open-source and portable.
- Not difficult for me to extend the software.
Tool 1, 2 and 3 are not open source. Tool 4 is mature, but not easy to extend.
After some research, I found plain text accounting. Three popular implementations are ledger, hledger and Beancount. I chose Beancount after reading some comparisons 1 2.
Beancount uses a custom syntax to describe transaction data in text files. Storing data in text files means we can store them locally. In addition, we can use a verson control tool such as git.
An include command inserts data from other text files. This is similar to #include
in C/C++ or import
in Python. This means we can build the transaction data as if we are coding a program. We can organize different parts of our transaction data into different files. We can also add new files later as we obtain new accounts in real life. For example, I am planning to use Beancount for tracking spending first and then later investment tracking.
Beancount is open-source, written in Python and has a plug-in API. Although a newer version will have C/C++ code, the Python API will stay. Python has Pandas, which is great for time-series and table-data manipulations. This makes writing custom bank-to-beancount converter easier. An plug-in API makes it possible for me to extend it. A Python program runs locally on Linux, macOS and Windows.
Beancount comes with a GUI called fava. It is a web application and open-source. It can run locally and works with any browser. Beancount comes with financial data of a fake person. Here is some screenshots from fava.
Each color is a different expense (i.e. spending) category:
Size of each square is proportional to the securities’s share of value in the portfolio.